/*
{
"id": 123,
"name": "aaa",
"thumb": ""
}
*/

import 'package:flutter/cupertino.dart';

class FileListItem {
  int id;
  String name;
  String cType;
  String thumb;
  String thumbSquare;

  FileListItem({this.id, this.name, this.thumb, this.cType});

  static FileListItem fromJson(Map<String, dynamic> json) {
    return FileListItem(
      id: json['id'],
      name: json['name'],
      thumb: json['thumb'],
      cType: json['type'],
    );
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    data['id'] = this.id;
    data['name'] = this.name;
    data['thumb'] = this.thumb;
    data['type'] = this.cType;
    return data;
  }
}

class AlbumViewerArguments {
  final List<FileListItem> albums;
  final int index;

  AlbumViewerArguments({@required this.albums, @required this.index});
}
